<?php

use Illuminate\Routing\Router;

use Illuminate\Support\Facades\Route;

Admin::registerAuthRoutes();

Route::group([
    'prefix' => config('admin.route.prefix'),
    'namespace' => config('admin.route.namespace'),
    'middleware' => config('admin.route.middleware'),
], function (Router $router) {
    $router->get('/', 'HomeController@index');

    Route::prefix('apidoc')->group(function (Router $router){
        $router->resource('project', 'ApiDoc\ApiProjectController');
        $router->resource('api', 'ApiDoc\ApiController');
        $router->resource('api_category', 'ApiDoc\ApiCategoryController');
        $router->resource('api_var', 'ApiDoc\ApiVarController');
        $router->resource('api_preset', 'ApiDoc\ApiRequestPresetController');
        $router->resource('request_body', 'ApiDoc\ApiRequestBodyController');
        $router->resource('response_body', 'ApiDoc\ApiResponseBodyController');
    });

});
